import pygame.time

from actor.welcome_sprite import WelcomeSpriteWin
from scene import BaseScene

"""
欢迎场景类
"""


class WinScene(BaseScene):
    def __init__(self, xiao_tie):
        """
        胜利场景参数初始化
        :param xiao_tie: 小铁精灵类
        """
        super(WinScene, self).__init__(xiao_tie,
                                       "./resources/images/win/win.jpg")
        self.actor = WelcomeSpriteWin(50, 300)
        pygame.mixer.music.load("resources/sound/成功通关.wav")
        pygame.mixer.music.play(-1)

    def draw_actor(self):
        """
        绘制胜利场景精灵类
        :return:
        """
        self.actor.draw(self.current_surface, 0, 0)

    def run(self, key_down_flag, key_list):
        """
        实现精灵运动效果
        :param key_down_flag:
        :param key_list:
        :return:
        """
        pass
